﻿using Microsoft.AspNetCore.Mvc;
using WMS_MAV;

namespace MVC_System.Controllers
{
    public class LoginController : Controller
    {
        /// <summary>
        /// 登录视图
        /// </summary>
        /// <returns></returns>
        public IActionResult Login()
        {
            return View();
        }
        /// <summary>
        /// 登录方法
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        [HttpPost]
        public async Task<ActionResult> LogouAdd(string model)
        {
            HttpClientWrapper httpClient = new HttpClientWrapper(model);
            string url = "http://47.96.109.219:5202/api/Login/Login";
            var response= await httpClient.PostAsync(url,model);
            return Json(response);
        }
    }
}
